<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>双面小球</title>
    <style>
        /*思路是让两个div背靠背，然后翻转大盒子就行*/
        body{
            perspective: 800px;
        }
        .bi{
            transform-style: preserve-3d;
            position: relative;
            margin: 100px auto;
            height: 300px;
            width: 300px;
            transition: all 1s;
        }
        .bi div:first-child,
        .bi div:last-child{
            position: absolute;
            left: 50px;
            top: 50px;
            height: 200px;
            width: 200px;
            border: 1px solid #000;
            border-radius: 50%;
            text-align: center;
            line-height: 200px;
        }
        .bi div:first-child{
            z-index: 1;
            background: blue;
        }
        .bi div:last-child{
            background: brown;
            transform:rotateY(180deg);
        }
        .bi:hover{
            transform: rotateY(180deg);
        }
    </style>
</head>
<body>
    <div class="bi">
        <div class="z1">我是正面啦！</div>
        <div class="z2">我是背面？？</div>
    </div>
</body>
</html>